//
//  RootVCOfSencondTVC.m
//  To Feel
//
//  Created by 曹宇 on 16/7/14.
//  Copyright © 2016年 caoyu. All rights reserved.
//

#import "RootVCOfSencondTVC.h"
#import "TVCOfDetailVideo.h"
#import "Masonry.h"
@interface RootVCOfSencondTVC ()

@end

@implementation RootVCOfSencondTVC

- (instancetype)initWithIdOfPage:(NSString *)idOfPage {
    
    self = [super init];
    if (self) {
        
        self.idOfPage = idOfPage;
        [self creatTableView];
        
    }
    return self;
    
}

- (void)viewDidLoad {
    [super viewDidLoad];
}

- (void)backToVideoHome:(UIButton *)button {
    
    [self.navigationController popToRootViewControllerAnimated:YES];
}

- (void)creatTableView {
    
    self.tv = [[TVCOfDetailVideo alloc] init];
    self.tv.idOfUrl = self.idOfPage;
    [self.view addSubview:self.tv.view];
    [self addChildViewController:self.tv];
    
    
    [self.tv.view mas_makeConstraints:^(MASConstraintMaker *make) {
        make.top.equalTo(self.view).offset(0);
        make.leading.equalTo(self.view);
        make.width.equalTo(self.view);
        make.bottom.equalTo(self.view).offset(-49);
    }];
}






@end
